package com.test.liuhb.test.entity;

import com.google.gson.annotations.Expose;

import java.util.List;

/**
 * Created by liu.hb on 2018/2/22.
 */

public class Category {
    @Expose
    public int id;
    @Expose public String name;
    @Expose public List<Category> children;
    //不需要序列化,所以不加 @Expose 注解，
    // 等价于 @Expose(deserialize = false,serialize = false)
    public String parent;

    public Category(int id, String name, List<Category> children, String parent) {
        this.id = id;
        this.name = name;
        this.children = children;
        this.parent = parent;
    }
}
